package Classic150;

public class 阶乘后的零 {
    /*
        数学，计算有多少个因数5
     */
    public int trailingZeroes(int n) {
        int count = 0;
        while (n > 0) {
            count += n / 5;
            n /= 5;
        }
        return count;
    }
}
